package farmer.gui;

import java.awt.geom.RoundRectangle2D;

import core.gui.Button;
import farmer.game.Data;
import farmer.game.FarmerBoyGame;
import farmer.game.InGameMenuState;
import farmer.game.MainGameState;

public class MainGameMenuButton extends Button{

	private MainGameState state;
	
	public MainGameMenuButton(String name, MainGameState state) {
		super(name);
		this.state = state;
		this.boundingRect = new RoundRectangle2D.Float(0, 0, 10, 10, 10, 10);
	}
	
	public void isClicked(){
		InGameMenuState.image = state.getImage();
		Data.status = Data.paused;
		state.getGame().enterState(FarmerBoyGame.InGameMenu);
	}

}
